<%@ page pageEncoding="UTF-8"%>
<%@ taglib uri="http://java.sun.com/jstl/core_rt" prefix="c"%>
<%@include file="../../../pageHead.jsp"%>
<c:choose>
<c:when test="${not empty setting.user}">

		<c:set var="proceedParames"
			value="workflowId=${actionItem.workflowId}&actionId=${actionItem.actionId}&nextOwners[0].owner=${setting.user}&nextOwners[0].stepId=${actionItem.stepId}" />
		<script type="text/javascript">
   			var url = "../../../workflow/proceed/proceed!proceed";
	    	var ps = "${proceedParames}";
	    	$.post(url,ps,function(){
	    		 window.location.href="../../../index.jsp";
	    	});
   		</script>

</c:when>
<c:otherwise>
<script type="text/javascript">
	var wfsetting = {
			"name":"${setting.id.name}",
			"stepId":"${setting.id.stepId}",
            "actionId":"${setting.id.actionId}"
	};
	var action = {
			"actionId":'${actionItem.actionId}',
			"stepId":'${actionItem.stepId}',
			"workflowId":'${actionItem.workflowId}',
			"username":""
	};
	
</script>
<link rel="stylesheet"	href="${sbase}scripts/zTree/css/zTreeStyle/zTreeStyle.css"	type="text/css" />
<script type="text/javascript"	src="${sbase}scripts/zTree/js/jquery.ztree.core-3.3.js"></script>
<script type="text/javascript" src="${sbase}scripts/zTree/js/jquery.ztree.excheck-3.3.js"></script>
<script type="text/javascript"
			src="../../../scripts/apps/admin/form/show/saveform.js"></script>		
		<title>选人并提交活动</title>
		<style type="text/css">
			.rightUsers {
				width: 500px;
				height: auto;
				border: #345 1px dotted;
				margin: 0 auto;
			}
		</style>

	<div class="rightUsers">
		<button  onclick="submitwork()" class="btn btn-primary btn-large btn-block">
			<i class="icon-user"></i>
			提交公务
		</button>
		<br />
		<ul id="usersTree" class="ztree"></ul>
		<button  onclick="submitwork()" class="btn btn-primary btn-large btn-block">
		   <i class="icon-user"></i>
			提交公务
		</button>
	</div>
</c:otherwise>
</c:choose>
<%@include file="../../../pageFoot.jsp"%>